import { tableServiceInterface } from "@/common/interface/table.interface";
import {
  $musicApplicationChordsList,
  $musicApplicationChordsDetail,
  $musicApplicationChordsAdd,
  $musicApplicationChordsUpdate,
  $musicApplicationChordsDelete,
} from "@/apis/applicationChords/applicationChords";
import {
  musicApplicationChordsListInterface,
  musicApplicationChordsAddInterface,
  musicApplicationChordsUpdateInterface,
} from "@/apis/applicationChords/applicationChords.interface";
export default class ApplicationChordsService implements tableServiceInterface {
  async getTable(e: musicApplicationChordsListInterface): Promise<any> {
    return $musicApplicationChordsList(e);
  }
  deleteMultiple(e: Array<string>): Promise<any> {
    return $musicApplicationChordsDelete(e);
  }
  edit(e: musicApplicationChordsUpdateInterface): Promise<any> {
    return $musicApplicationChordsUpdate(e);
  }
  add(e: musicApplicationChordsAddInterface): Promise<any> {
    return $musicApplicationChordsAdd(e);
  }
  detail(id: string): Promise<any> {
    return $musicApplicationChordsDetail(id);
  }
  // 修改启用状态
  statusChange({ record, status }: { record: musicApplicationChordsUpdateInterface, status: number }) {
    record.status = status;
    return $musicApplicationChordsUpdate(record);
  }
}